﻿using Microsoft.Data.Sqlite;
using System;
using System.Collections.Generic;
using System.Data;
using System.Data.Common;
using System.Data.SqlClient;
using System.Text;

namespace CRL.Sqlite
{
    public class SqliteDataAdapter : DbDataAdapter
    {
        public new SqliteCommand DeleteCommand
        {
            get
            {
                return (SqliteCommand)base.DeleteCommand;
            }
            set
            {
                base.DeleteCommand = value;
            }
        }

        public new SqliteCommand InsertCommand
        {
            get
            {
                return (SqliteCommand)base.InsertCommand;
            }
            set
            {
                base.InsertCommand = value;
            }
        }

        public new SqliteCommand SelectCommand
        {
            get
            {
                return (SqliteCommand)base.SelectCommand;
            }
            set
            {
                base.SelectCommand = value;
            }
        }

        public new SqliteCommand UpdateCommand
        {
            get
            {
                return (SqliteCommand)base.UpdateCommand;
            }
            set
            {
                base.UpdateCommand = value;
            }
        }
        public SqliteDataAdapter()
        {
            GC.SuppressFinalize(this);
        }

        public SqliteDataAdapter(SqliteCommand selectCommand)
            : this()
        {
            SelectCommand = selectCommand;
        }

        public SqliteDataAdapter(string selectCommandText, SqliteConnection connection)
            : this(new SqliteCommand(selectCommandText, connection))
        {
        }

        public SqliteDataAdapter(string selectCommandText, string connectionString)
            : this(new SqliteCommand(selectCommandText, new SqliteConnection(connectionString)))
        {
        }
    }
}
